#include "mainwindow.h"
#include "ui_mainwindow.h"

#include<QDebug>
#include"mjson.h"

const auto C_STR = "{\"code\":403,\"key_must_string\":\"key must be string__- ok \"}";
MainWindow::MainWindow(QWidget *parent) :
    QMainWindow(parent),
    ui(new Ui::MainWindow)
{
    ui->setupUi(this);

    MJson mJson;
    mJson.setCode(200);
    mJson.setKeyMustString("key must be string");

    qDebug()<<mJson.toJSON();

   auto m =  MJson::parseFromJsonString(C_STR);

   qDebug()<<"m "<<m.toJSON();
}

MainWindow::~MainWindow()
{
    delete ui;
}
